﻿using System.Collections.Generic;
using System;
using System.Collections;
using UnityEngine;
using UnityEngine.SceneManagement;

namespace Super
{
	/// <summary>
	///	事件触发，传递参数的类型
	/// </summary>
	public class EventSimpleGE : IGameEvent
	{
		public EventSimpleGE() { }
	}
	
	#region 输入相关事件
	/// <summary>
	/// 鼠标按下事件
	/// </summary>
	public class MouseDownGE : IGameEvent
	{
		public MouseKey key;

		/// <param name="key">鼠标按钮枚举，0-左键、1-中键、2-右键</param>
		public MouseDownGE(MouseKey key)
		{
			this.key = key;
		}
	}

	/// <summary>
	/// 鼠标松开事件
	/// </summary>
	public class MouseUpGE : IGameEvent
	{
		public MouseKey key;

		/// <param name="key">鼠标按钮枚举，0-左键、1-中键、2-右键</param>
		public MouseUpGE(MouseKey key)
		{
			this.key = key;
		}
	}

	/// <summary>
	/// 鼠标拖拽事件
	/// </summary>
	public class MouseDragGE : IGameEvent
	{
		public MouseKey key;

		/// <param name="key">鼠标按钮枚举，0-左键、1-中键、2-右键</param>
		public MouseDragGE(MouseKey key)
		{
			this.key = key;
		}
	}

	/// <summary>
	/// 鼠标滚动
	/// </summary>
	public class MouseScrollGE : IGameEvent
	{
		public Vector2 delta;
		public MouseScrollGE(Vector2 delta)
		{
			this.delta = delta;
		}
	}

	/// <summary>
	/// 输入vector2方向事件
	/// </summary>
	public class InputDirectionGE : IGameEvent
	{
		public Vector2 value;
		public InputDirectionGE(Vector2 value)
		{
			this.value = value;
		}
	}

	/// <summary>
	/// 水平输入事件
	/// </summary>
	public class InputHorizontalGE : IGameEvent
	{
		public float value;

		public InputHorizontalGE(float value)
		{
			this.value = value;
		}
	}

	/// <summary>
	/// 垂直输入事件
	/// </summary>
	public class InputVerticalGE : IGameEvent
	{
		public float value;

		public InputVerticalGE(float value)
		{
			this.value = value;
		}
	}

	/// <summary>
	/// 功能按钮One按下
	/// </summary>
	public class FunBtnOneDownGE : IGameEvent
	{
		public FunBtnOneDownGE() { }
	}

	/// <summary>
	/// 功能按钮Two按下
	/// </summary>
	public class FunBtnTwoDownGE : IGameEvent
	{
		public bool isHold;
		public FunBtnTwoDownGE(bool isHold)
		{
			this.isHold = isHold;
		}
	}

	/// <summary>
	/// 功能按钮Three按下
	/// </summary>
	public class FunBtnThreeDownGE : IGameEvent
	{
		public FunBtnThreeDownGE() { }
	}

	/// <summary>
	/// 功能按钮Four按下
	/// </summary>
	public class FunBtnFourDownGE : IGameEvent
	{
		public FunBtnFourDownGE() { }
	}

	public class FunBtnFourHoldGE : IGameEvent
	{
		public FunBtnFourHoldGE() { }
	}

	/// <summary>
	/// 功能按钮Four按下
	/// </summary>
	public class FunBtnFiveDownGE : IGameEvent
	{
		public FunBtnFiveDownGE() { }
	}

	public class FunBtnFiveHoldGE : IGameEvent
	{
		public FunBtnFiveHoldGE() { }
	}

	/// <summary>
	/// 功能按钮Four按下
	/// </summary>
	public class FunBtnSixDownGE : IGameEvent
	{
		public FunBtnSixDownGE() { }
	}

	/// <summary>
	/// 组合按钮Run按下
	/// </summary>
	public class CombBtnRunGE : IGameEvent
	{
		public bool running;
		public CombBtnRunGE(bool runState)
		{
			running = runState;
		}
	}

	public class CombBtnDownAtkGE : IGameEvent
	{
		public CombBtnDownAtkGE() { }
	}

	public class EscBtnDown : IGameEvent
	{
		public EscBtnDown() { }
	}

	public class SpaceBtnDown : IGameEvent
	{
		public SpaceBtnDown() { }
	}

	public class TabBtnDown : IGameEvent
	{
		public TabBtnDown() { }
	}

	public class QBtnDownGE : IGameEvent
	{
		public QBtnDownGE() { }
	}

	public class EBtnDownGE : IGameEvent
	{
		public EBtnDownGE() { }
	}

	public class WBtnDownGE : IGameEvent
	{
		public WBtnDownGE() { }
	}

	public class ABtnDownGE : IGameEvent
	{
		public ABtnDownGE() { }
	}

	public class SBtnDownGE : IGameEvent
	{
		public SBtnDownGE() { }
	}

	public class DBtnDownGE : IGameEvent
	{
		public DBtnDownGE() { }
	}

	/// <summary>
	/// 数字键按下
	/// </summary>
	public class NumBtnDown : IGameEvent
	{
		public int num;
		public NumBtnDown(int num)
		{
			this.num = num;
		}
	}
	#endregion

	#region UI相关事件
	/// <summary>
	/// 面板打开事件
	/// </summary>
	public class PanelOpenGE : IGameEvent
	{
		public string panelName;
		public PanelBase panelBase;

		public PanelOpenGE(string panelName, PanelBase panelBase)
		{
			this.panelName = panelName;
			this.panelBase = panelBase;
		}
	}

	/// <summary>
	/// Widget打开事件
	/// </summary>
	public class WidgetOpenGE : IGameEvent
	{
		public string widgetName;
		public WidgetBase widgetBase;

		public WidgetOpenGE(string widgetName, WidgetBase widgetBase)
		{
			this.widgetName = widgetName;
			this.widgetBase = widgetBase;
		}
	}

	/// <summary>
	/// 面板关闭事件
	/// </summary>
	public class PanelCloseGE : IGameEvent
	{
		public string panelName;

		public PanelCloseGE(string panelName)
		{
			this.panelName = panelName;
		}
	}

	/// <summary>
	/// widget关闭事件
	/// </summary>
	public class WidgetCloseGE : IGameEvent
	{
		public string widgetName;

		public WidgetCloseGE(string widgetName)
		{
			this.widgetName = widgetName;
		}
	}
	
	#endregion

	

	#region Monobehaviour相关事件
	public class UpdateGE : IGameEvent
	{
		public float deltaTime;

		public UpdateGE(float deltaTime)
		{
			this.deltaTime = deltaTime;
		}
	}

	public class FirstUpdate : IGameEvent
	{

	}

	public class OnFixedUpdateGE : IGameEvent
	{

	}
	#endregion

	#region 交互事件
	public class ShowValueGE : IGameEvent
	{
		public Vector3 pos;
		public int value;
		public ShowValueColorType valueType;

		public ShowValueGE(Vector3 pos, int value, ShowValueColorType valueType)
		{
			this.pos = pos;
			this.value = value;
			this.valueType = valueType;
		}
	}

	public class AniChangeState : IGameEvent
	{
		public Animator ani;
		public AniState state;

		public AniChangeState(Animator ani, AniState state)
		{
			this.ani = ani;
			this.state = state;
		}
	}
	
	public class OnPlayerRunStateChange : IGameEvent
	{
		public bool state;
		public OnPlayerRunStateChange(bool runState)
		{
			state = runState;
		}
	}
	
	public class BtnClick : IGameEvent{ }
	
	public class ApplicationQuit : IGameEvent{ }
	
	#endregion
}


